#ifndef REMOTE_CLIENT_TASK_H_
#define REMOTE_CLIENT_TASK_H_

#include "remote/client/clientcontrolsession.h"

namespace remote {

class Task : public boost::noncopyable,
  public boost::enable_shared_from_this < Task > {
 public:
  typedef boost::shared_ptr<Task> Ptr;


  boost::signals2::signal<void(
    Task::Ptr session,
    QueryStanza::Ptr stanza,
    uint32 error_code)> SignalTaskDone;

  Task(boost::asio::io_service &io_service, QueryStanza::Ptr req_stanza);
  virtual ~Task();

  bool HandleStanza(QueryStanza::Ptr stanza);
 private:
  boost::asio::io_service &io_service_;
  QueryStanza::Ptr req_stanza_;
};

}

#endif  // REMOTE_CLIENT_TASK_H_
